package com.topisv.tms.entity;

import java.util.Date;
import java.util.List;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Table;
import javax.persistence.Transient;

/**
 * 任务批次表
 * @author Administrator
 *
 */
@Entity
@Table(name = "batch_task")
public class BatchTask extends IdEntity {

	/**
	 * 
	 */
	private static final long serialVersionUID = 1L;
	
	private String warehouseCode;//商家仓库编码
	
	public String getWarehouseCode() {
		return warehouseCode;
	}
	public void setWarehouseCode(String warehouseCode) {
		this.warehouseCode = warehouseCode;
	}
	private String batchType;
	@Column(name="batch_type")
	public String getBatchType() {
		return batchType;
	}
	public void setBatchType(String batchType) {
		this.batchType = batchType;
	}
	private String areaGroupName;//网点名称
	@Column(name="area_group_name")
	public String getAreaGroupName() {
		return areaGroupName;
	}
	public void setAreaGroupName(String areaGroupName) {
		this.areaGroupName = areaGroupName;
	}
	private String shopSourceCode;//平台编码
	private String customerCode;//客户编码
	@Column(name="shop_source_code")
	public String getShopSourceCode() {
		return shopSourceCode;
	}
	public void setShopSourceCode(String shopSourceCode) {
		this.shopSourceCode = shopSourceCode;
	}
	@Column(name="customer_code")
	public String getCustomerCode() {
		return customerCode;
	}
	public void setCustomerCode(String customerCode) {
		this.customerCode = customerCode;
	}
	private String backupTaskNumber ;
	private String areaGroupCode;//网点编码
	@Column(name="area_group_code")
	public String getAreaGroupCode() {
		return areaGroupCode;
	}
	public void setAreaGroupCode(String areaGroupCode) {
		this.areaGroupCode = areaGroupCode;
	}
	@Transient
	public String[] getBackupTaskNumberLists() {
		if(null==backupTaskNumber){
			return null;
		}
		return backupTaskNumber.split(",");
	}
	@Transient
	public String getBackupTaskNumber() {
		return backupTaskNumber;
	}
	public void setBackupTaskNumber(String backupTaskNumber) {
		this.backupTaskNumber = backupTaskNumber;
	}

	private String username;
	@Transient
	public String getUsername() {
		return username;
	}
	public void setUsername(String username) {
		this.username = username;
	}
	private String batchTaskCode;// varchar(20) NOT NULL COMMENT '批次任务编号',
	private String  jobuuid ;//varchar(64) NOT NULL COMMENT '操作人id号',
	private String type ;//varchar(10) DEFAULT NULL COMMENT '任务类型 单件single 多件 ',  
	private String  date;// varchar(10) DEFAULT NULL COMMENT '时间周期 ',
	private String  status;// varchar(30) NOT NULL COMMENT '状态：可选值:已经处理finish、未处理pending',  
	private int  ordenoQty;// int(10) DEFAULT 0 COMMENT '订单数量 ',  
	private int  skuQty;// int(10) DEFAULT 0 COMMENT '商品数量 ',
	private int  skuType ;//int(30) DEFAULT 0 COMMENT '商品类型数量',
	@Column(name="batch_task_code")
	public String getBatchTaskCode() {
		return batchTaskCode;
	}
	public void setBatchTaskCode(String batchTaskCode) {
		this.batchTaskCode = batchTaskCode;
	}
	public String getJobuuid() {
		return jobuuid;
	}
	public void setJobuuid(String jobuuid) {
		this.jobuuid = jobuuid;
	}
	public String getType() {
		return type;
	}
	public void setType(String type) {
		this.type = type;
	}
	public String getDate() {
		return date;
	}
	public void setDate(String date) {
		this.date = date;
	}
	public String getStatus() {
		return status;
	}
	public void setStatus(String status) {
		this.status = status;
	}
	@Column(name="ordeno_qty")
	public int getOrdenoQty() {
		return ordenoQty;
	}
	public void setOrdenoQty(int ordenoQty) {
		this.ordenoQty = ordenoQty;
	}
	@Column(name="sku_qty")
	public int getSkuQty() {
		return skuQty;
	}
	public void setSkuQty(int skuQty) {
		this.skuQty = skuQty;
	}
	@Column(name="sku_type")
	public int getSkuType() {
		return skuType;
	}
	public void setSkuType(int skuType) {
		this.skuType = skuType;
	}
	@Column(name="create_date")
	public Date getCreateDate() {
		return createDate;
	}
	public void setCreateDate(Date createDate) {
		this.createDate = createDate;
	}
	@Column(name="update_date")
	public Date getUpdateDate() {
		return updateDate;
	}
	public void setUpdateDate(Date updateDate) {
		this.updateDate = updateDate;
	}
	private Date  createDate;// date DEFAULT NULL COMMENT '备货时间',  
	private Date  updateDate;// date DEFAULT NULL COMMENT '处理时间',
	
	//dto属性
	private List<BackupTaskOrdeno> orderList;
	
	@Transient
	public List<BackupTaskOrdeno> getOrderList() {
		return orderList;
	}

	public void setOrderList(List<BackupTaskOrdeno> orderList) {
		this.orderList = orderList;
	}

}
